#ifndef __GST_DYNAMIC_TEXT_H__
#define __GST_DYNAMIC_TEXT_H__

#include <gst/gst.h>
#include <gst/video/video.h>
#include <gst/video/gstvideofilter.h>

G_BEGIN_DECLS

#define GST_TYPE_DYNAMIC_TEXT (gst_dynamic_text_get_type())
#define GST_DYNAMIC_TEXT(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), GST_TYPE_DYNAMIC_TEXT, GstDynamicText))
#define GST_DYNAMIC_TEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), GST_TYPE_DYNAMIC_TEXT, GstDynamicTextClass))
#define GST_IS_DYNAMIC_TEXT(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), GST_TYPE_DYNAMIC_TEXT))
#define GST_IS_DYNAMIC_TEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), GST_TYPE_DYNAMIC_TEXT))

typedef struct _GstDynamicText GstDynamicText;
typedef struct _GstDynamicTextClass GstDynamicTextClass;

struct _GstDynamicText
{
    GstVideoFilter parent;

    /* 私有数据 */
    gchar *text;
    gint font_size;
    gchar *font_name;
    gdouble x_position;
    gdouble y_position;
    gdouble scroll_speed;
    gint scroll_direction; /* 0: 水平, 1: 垂直 */
    guint color;    /*big-endian ARGB格式*/
};

struct _GstDynamicTextClass
{
    GstVideoFilterClass parent_class;
};

GType gst_dynamic_text_get_type(void);

G_END_DECLS

#endif /* __GST_DYNAMIC_TEXT_H__ */